//
//  VersionManager.h
//  SWCommonFrame
//
//  Created by shaowei on 13-6-18.
//  Copyright (c) 2013年 shaowei. All rights reserved.
//

#import <Foundation/Foundation.h>

typedef void (^VersionCheckComplete)(BOOL checkResult, BOOL isNeedUpdate, CGFloat currentVersion, CGFloat newestVersion);

#define APP_UPDATE_URL @"https://itunes.apple.com/lookup?id="
#define APP_GET_URL @"https://itunes.apple.com/cn/app/id"

@interface VersionCheck : NSObject

+ (void)setAppID:(NSString *)appID;
+ (void)setUpdateIntervalTime:(CGFloat)intervalTime;  //以“天”为单位,默认一天
+ (BOOL)isNeedCheckUpdate;
+ (void)checkUpdateIsNeedDefaultPrompt:(BOOL)isNeed complete:(VersionCheckComplete)complete;


+ (void)forbidPromptInVersion:(CGFloat)versionNum;
+ (CGFloat)getAppVersionNumber;

@end

